//
//  PostListHeaderView.h
//  BaseProject
//
//  Created by 王洋 on 2020/12/10.
//  Copyright © 2020 王洋. All rights reserved.
//

#import <UIKit/UIKit.h>
#import "CommunityThemeModel.h"

NS_ASSUME_NONNULL_BEGIN

typedef NS_ENUM(NSInteger, PostListHeaderViewActionType) {

    PostListHeaderViewActionType_back,
    
    PostListHeaderViewActionType_hot,

    PostListHeaderViewActionType_new,

    PostListHeaderViewActionType_other
};

@interface PostListHeaderView : UIView


@property (weak, nonatomic) IBOutlet NSLayoutConstraint *topHeight;

@property (weak, nonatomic) IBOutlet UIImageView *mainImageView;

@property (weak, nonatomic) IBOutlet UIImageView *bgImageView;


@property (weak, nonatomic) IBOutlet UILabel *mainTitleLab;

@property (weak, nonatomic) IBOutlet UILabel *subTitleLab;

@property (weak, nonatomic) IBOutlet UIView *segView;


//最新
@property (weak, nonatomic) IBOutlet UIButton *hotestBtn;
@property (weak, nonatomic) IBOutlet UIView *hotSlide;

//最热
@property (weak, nonatomic) IBOutlet UIButton *newestBtn;
@property (weak, nonatomic) IBOutlet UIView *newestSlide;




@property (nonatomic, copy) void(^PostListHeaderViewBlock)(PostListHeaderViewActionType type);


+ (CGFloat)calculateHeight;

- (void)fillWithModel:(CommunityThemeModel *)model;



@end

NS_ASSUME_NONNULL_END
